
package misEjemplos;


public class Operaciones {
    //Declaracion de los atributos
    private int num1;
    private int num2;
    //metodo constructor de la clase
    public Operaciones(){
      num1=0;
      num2=0;
    }
    //metodo modificador
    public void setNum1(int num1) {
	this.num1 = num1;
}
   //metodo selector
  public int getNum1() {
	return num1;
}
  
  public void setNum2(int num2) {
      this.num2 = num2;
  }


   public int getNum2() {
	return num2;
}

  public int Suma(){
     int suma;
     suma= getNum1()+getNum2();
     return suma;
  }
public int Resta(){
     int res;
     res= getNum1()-getNum2();
     return res;
  }
    
public int Multiplicacion(){
     int mul;
     mul= getNum1()*getNum2();
     return mul;
  }

public double Division(){
   float div;
    div=(float)getNum1()/(float)getNum2();
    return div;
}

}
